package com.example.service.impl;

import com.example.dto.SetmealDto;
import com.example.mapper.SetmealMapper;
import com.example.pojo.Setmeal;
import com.example.pojo.User;
import com.example.service.SetmealService;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public  class SetmealServiceImpl implements SetmealService {
    @Autowired
    private SetmealMapper setmealMapper;

    @Override
    public List<SetmealDto> getSetmealWithCheckItems(int gender) {
        // 注意这里type=1为男性，type=0为女性，根据实际需求调整
        return setmealMapper.getSetmealWithCheckItems(gender);
    }

    @Override
    public int getTotalSetmealCount(int gender) {
        return setmealMapper.getTotalSetmealCount(gender);
    }

    @Override
    public Setmeal getSetmealById(int smId) {
        return null;
    }

    @Override
    public Setmeal getSetmealById(Integer smId) {
        return setmealMapper.getSetmealById(smId);
    }

}